var query = require('./DB');
var asyncQuery = function (sql, sqlParams) {
    return new Promise((resolve, rejected) => {
        query(sql, sqlParams, function (qerr, vals, fields) {
            if (qerr) {
                rejected(qerr);
            } else {
                resolve(vals);
            };
        });
    });
};
module.exports = asyncQuery;


